Learning heuristics for basic block instruction scheduling

نویسندگان

  • Abid M. Malik
  • Tyrel Russell
  • Michael Chase
  • Peter van Beek
چکیده

Instruction scheduling is an important step for improving the performance of object code produced by a compiler. A fundamental problem that arises in instruction scheduling is to find a minimum length schedule for a basic block—a straight-line sequence of code with a single entry point and a single exit point—subject to precedence, latency, and resource constraints. Solving the problem exactly is known to be difficult, and most compilers use a greedy list scheduling algorithm coupled with a heuristic. The heuristic is usually hand-crafted, a potentially time-consuming process. In contrast, we present a study on automatically learning good heuristics using techniques from machine learning. In our study, a recently proposed optimal basic block scheduler was used to generate the machine learning training data. A decision tree learning algorithm was then used to induce a simple heuristic from the training data. The automatically constructed decision tree heuristic was compared against a popular critical-path heuristic on the SPEC 2000 benchmarks. On this benchmark suite, the decision tree heuristic reduced the number of basic blocks that were not optimally scheduled by up to 55% compared to the critical-path heuristic, and gave improved performance guarantees in terms of the worst-case factor from optimality.

برای دانلود رایگان متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Basic-block Instruction Scheduling Using Reinforcement Learning and Rollouts

The execution order of a block of computer instructions on a pipelined machine can make a difference in its running time by a factor of two or more. In order to achieve the best possible speed, compilers use heuristic schedulers appropriate to each specific architecture implementation. However, these heuristic schedulers are time-consuming and expensive to build. We present empirical results us...

متن کامل

Learning basic block scheduling heuristics from optimal data

Instruction scheduling is an important step for improving the performance of object code produced by a compiler. The basic block instruction scheduling problem is to find a minimum length schedule for a basic block—a straightline sequence of code with a single entry point and a single exit point—subject to precedence, latency, and resource constraints. Solving the problem exactly is known to be...

متن کامل

Learning Policies for Local Instruction Scheduling

Execution speed of programs on modern computer architectures is sensitive, by a factor of two or more, to the order in which instructions are presented to the processor. To realize potential execution efficiency, it is now customary for an optimizing compiler to employ a heuristic algorithm for instruction scheduling. These algorithms are currently hand-crafted. We show how to cast the local in...

متن کامل

Using Machine Learning to Build Flexible Instruction Schedulers

Hardware implementations of a given computer architecture proliferate quickly; every few months new generations of chips are announced. However compilers do not keep this pace, because of the time consuming process of tailoring optimization and code generation for specific architectures. We want to automate parts of the compiler development process using adaptive techniques, such as machine lea...

متن کامل

Optimal Global Instruction Scheduling Using Enumeration

Instruction scheduling is one of the most important compiler optimizations. An instruction scheduler reorders instructions to improve performance by minimizing pipeline stalls. Traditional approaches to instruction scheduling were based on heuristics. Over the past decade, however, a number of researchers have proposed optimal solutions to instruction scheduling. This dissertation presents the ...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

عنوان ژورنال:
  • J. Heuristics

دوره 14  شماره 

صفحات  -

تاریخ انتشار 2008